<template>
	<view class="about-page">
		<view class="top">
			<view class="logo">

			</view>
			<view class="url">
				{{webUrl}}
			</view>
		</view>
		<view class="bottom">
			<view style="color: #1a68e8;" @click="go_user">
				《用户协议》
			</view>
			<view>ICP备案号：{{copyRight}}</view>
			<view>{{siteName}}版权所有</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				webUrl: "",
				copyRight: "",
				siteName: ""
			}
		},
		onShow() {
			this.webUrl = window.origin
			this.getSetting()
		},
		methods: {
			getSetting() {
				uni.request({
					url: "/api/index/getSetting",
					method: "POST"
				}).then(res => {
					console.log(res);
					this.copyRight = res.data.data.copyRight
					this.siteName = res.data.data.site_name
				})
			},
			go_user() {
				uni.navigateTo({
					url: "/pages/user_xy/user_xy"
				})
			}
		}
	}
</script>

<style scoped lang="scss">
	.about-page {
		width: 100vw;
		height: 94vh;
		background-color: white;
		overflow: hidden;
		position: relative;

		.top {
			width: 60%;
			height: 400rpx;
			margin: auto;
			margin-top: 100rpx;
			overflow: hidden;

			.logo {
				width: 300rpx;
				height: 200rpx;
				background-image: url("../../../static/image/logo.jpg");
				background-size: contain;
				margin: auto;
			}

			.url {
				width: 100%;
				text-align: center;
				font-size: 28rpx;
				margin-top: 50rpx;
				color: #949494;
			}
		}

		.bottom {
			width: 70%;
			height: 200rpx;
			position: absolute;
			bottom: 0rpx;
			left: 15%;
			text-align: center;

			>view {
				margin-top: 10rpx;
				font-size: 24rpx;
				color: #949494;
			}
		}
	}
</style>